import Vue from 'vue';
import Vuex from 'vuex';
import mutations from './mutations';
import actions from './actions';

Vue.use(Vuex);

export default new Vuex.Store({
  state: {
    locale: localStorage.getItem('locale') ? localStorage.getItem('locale') : 'zh_CN',
    Authorization: localStorage.getItem('Authorization') || null,
    imgUrl:'http://118.24.31.25:8889/recruit-portal-api/v1/common/download?group=',
    userInfo: localStorage.getItem('userInfo') ? JSON.parse(localStorage.getItem('userInfo')) : null,
  },
  getters: {
    // isLogined(state) {
    //   return state.Authorization ? true : false;
    // },
  },
  mutations,
  actions
})